Skip to content

fix(deps): pin esbuild ≥0.28.1 via pnpm-workspace overrides (GHSA-gv7w-rqvm-qjhr)#1910

Merged
os-zhuang merged 1 commit into
mainfrom
fix/pnpm-overrides-esbuild-advisory
Jun 15, 2026
Merged

fix(deps): pin esbuild ≥0.28.1 via pnpm-workspace overrides (GHSA-gv7w-rqvm-qjhr)#1910
os-zhuang merged 1 commit into
mainfrom
fix/pnpm-overrides-esbuild-advisory

Conversation

@os-zhuang

Copy link
Copy Markdown
Contributor

Problem

The Validate Package Dependencies CI job (pnpm audit --audit-level=high) fails on every dependency-touching PR with a high-severity esbuild advisory — GHSA-gv7w-rqvm-qjhr, affecting esbuild >=0.17.0 <0.28.1 via tsup → esbuild, tsx → esbuild, and vite → esbuild.

Root cause

pnpm v10 reads overrides from pnpm-workspace.yaml, not from package.json's pnpm field — that's the recurring [WARN] The "pnpm" field in package.json is no longer read by pnpm … pnpm.overrides … ignored message in every install.

Consequences on main:

  • The repo's existing minimatch / tar pins live in package.json's pnpm.overridessilently ignored (dead security pins).
  • Nothing pins esbuild at all → tsup/tsx/vite resolve 0.27.7 and 0.28.0 (both < 0.28.1, vulnerable). The lockfile carried three esbuild versions.

Fix

  • Add a real overrides: block to pnpm-workspace.yaml: esbuild: '>=0.28.1' + the migrated minimatch / tar pins.
  • Drop the now-redundant pnpm.overrides from package.json.

Result

  • esbuild collapses to a single 0.28.1 across the whole tree.
  • pnpm audit --audit-level=high: 2 high → 0 (now 2 low | 5 moderate); total advisories 11 → 7 (the migrated minimatch/tar pins also re-applied).
  • Verified the forced bump doesn't break tooling: @objectstack/formula tsup build succeeds and vitest 95/95 pass on esbuild 0.28.1.

Test-only tooling/lockfile change — no published-package code changes; empty changeset.

🤖 Generated with Claude Code

…w-rqvm-qjhr)

pnpm v10 reads `overrides` from `pnpm-workspace.yaml`, NOT package.json's `pnpm`
field (hence the recurring "pnpm field ignored" warning). The repo's minimatch
/tar pins lived in package.json and were therefore silently dead, and nothing
pinned esbuild at all — so `tsup`/`tsx`/`vite` resolved esbuild 0.27.7 and 0.28.0
(both < 0.28.1), tripping the high-severity advisory GHSA-gv7w-rqvm-qjhr that
fails `pnpm audit --audit-level=high` (the "Validate Package Dependencies" CI job)
on every dependency-touching PR.

Fix: add a real `overrides:` block to pnpm-workspace.yaml — `esbuild: '>=0.28.1'`
plus the migrated minimatch/tar pins — and drop the dead `pnpm.overrides` from
package.json. esbuild now resolves to a single 0.28.1 across the tree; high
advisories drop from 2 to 0. tsup build + vitest verified working on 0.28.1.

Test-only tooling/lockfile change; empty changeset.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@vercel

vercel Bot commented Jun 15, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
spec Ready Ready Preview, Comment Jun 15, 2026 1:16pm

Request Review

@github-actions github-actions Bot added documentation Improvements or additions to documentation dependencies Pull requests that update a dependency file tooling size/s labels Jun 15, 2026
@os-zhuang
os-zhuang merged commit dd66bb6 into main Jun 15, 2026
14 checks passed
@os-zhuang
os-zhuang deleted the fix/pnpm-overrides-esbuild-advisory branch June 15, 2026 13:19
os-zhuang added a commit that referenced this pull request Jun 22, 2026
chore: release packages (#1910)

objectui@cba0c6d586a2e8ad25d8316361f69dd5e5f34a7b
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file documentation Improvements or additions to documentation size/s tooling

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant